home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1997 April / EnigmA AMIGA RUN 17 (1997)(G.R. Edizioni)(IT)[!][issue 1997-04][EAR-CD].iso / EARCD / comm / www / IBGoldEd.lha / IBGoldEd.ibrx next >
Text File  |  1996-12-18  |  2KB  |  64 lines

  1. /* IBGoldEd V1.0 ©1996 Roy E Brown <roy@ebrown.demon.co.uk>
  2.  
  3.    $VER: IBGoldED.ibrx V1.0 (18.12.96)
  4.  
  5.    A script for use with IBrowse to pass the active LOCAL file to
  6.    GoldED for editing.
  7.  
  8.    Add it to your IBrowse Arexx menu.
  9. */
  10.  
  11. Options Results
  12. Options failat 21
  13.  
  14. Vers="IBGoldEd V1.0 ©1996 Roy Brown"
  15. tags="rtez_flags=ezreqf_centertext"
  16.  
  17. /* Check for rexxreqtools.library */
  18. If ~Show('L','rexxreqtools.library') Then
  19. Do
  20.   If ~Exists('Libs:rexxreqtools.library') Then
  21.     Do
  22.       If Exists('C:RequestChoice') Then
  23.         Do
  24.           Address Command
  25.           'RequestChoice >NIL: "System Information" "IBGoldEd.ibrx Error!*nCannot find required library.*nPlease consult documentation" "Thank You"'
  26.         End
  27.       Else
  28.          Say "IBGoldEd.ibrx Error Cannot find required library. Please consult documentation"
  29.       Exit
  30.     End
  31.   AddLib('rexxreqtools.library',0,-30,0)
  32. End
  33.  
  34. If ~Show('P','IBROWSE') Then
  35.   Do
  36.     Call RTEZREQUEST("Ibrowse doesn't appear to be loaded","Oops",Vers,tags)
  37.     Exit
  38.   End
  39.  
  40. Address IBROWSE
  41.  
  42. 'QUERY URL'  /* Will automatically select the active IBrowse window */
  43.  
  44. If RESULT='' Then
  45.   Do
  46.     Call RTEZREQUEST("There is no LOCAL file loaded in IBROWSE","Oops",Vers,tags)
  47.     Exit
  48.   End
  49.  
  50. If Left(RESULT,4)~="file" Then
  51.   Do
  52.     Call RTEZREQUEST("This script will only work on LOCAL files","Oops",Vers,tags)
  53.     Exit
  54.   End
  55.  
  56. LocalHTML=Substr(RESULT,9)
  57.  
  58. If ~Show('P','GOLDED.1') Then
  59.   Address Command 'Ed 'LocalHTML''
  60. Else
  61.   Address GOLDED.1 'OPEN NEW NAME 'LocalHTML''
  62.  
  63. Exit
  64.